package com.feinno.urcs.group.api;

import com.feinno.urcs.group.entity.GroupInfo;
import com.feinno.urcs.group.entity.GroupMember;
import com.feinno.urcs.types.MobileNo;
import org.helium.framework.annotations.ServiceInterface;

import java.util.List;
import java.util.Map;

/**
 * Created by honghao on 7/22/15.
 */
@ServiceInterface(id = "group:GroupCacheManager")
public interface GroupCacheManager {

	void setGroupInfo(GroupInfo info);

	GroupInfo getGroupInfo(int groupId) throws IllegalAccessException, InstantiationException;

	GroupMember getGroupMemberInfo(int groupId, MobileNo mobileNo) throws IllegalAccessException, InstantiationException;

	void setGroupMemberInfo(int groupId, GroupMember groupMember);

	void setGroupMemberInfos(int groupId, List<GroupMember> groupMembers);

	List<GroupMember> getPartGroupMembers(int groupId, MobileNo... mobileNos);

	List<GroupMember> getGroupMembers(int groupId);

	void removeGroupMember(int groupId, MobileNo mobileNo);

	void clearGroup(int groupId);
}
